package com.da.lon.wang.xlg.util;

import java.util.HashMap;

public class SingleManager {
    private static SingleManager _instance = null;

    private HashMap<String, int[]> map = new HashMap<String, int[]>();

    public static SingleManager getInstance() {
        if (_instance == null) {

            _instance = new SingleManager();
        }
        return _instance;
    }

    public int[] getMap(String i) {
        if (map.containsKey(i)) {
            int[] result = map.get(i);
            return result;
        } else {
            return null;
        }

    }

    public void setMap(String i, int[] res) {
        if (map.containsKey(i)) {
            map.remove(i);
        }
        this.map.put(i, res);
    }
}
